package structures;

import java.util.ArrayList;
import java.util.List;

public class Page {
	private Lock block;
	private List<Row> rows;
	private Table parent;
	
	public Page(Table parent){
		rows = new ArrayList<Row>();
		this.parent = parent;
	}
	
	public Page(Lock block, List<Row> rows, Table parent) {
		super();
		this.block = block;
		this.rows = rows;
		this.parent = parent;
	}
	
	public Table getParent() {
		return parent;
	}

	public Lock getBlock() {
		return block;
	}

	public void setBlock(Lock block) {
		this.block = block;
	}

	public List<Row> getRows() {
		return rows;
	}

	public void setRows(List<Row> rows) {
		this.rows = rows;
	}

	public void setParent(Table parent) {
		this.parent = parent;
	}
	
	public void addRow(Row tup) {
		rows.add(tup);
	}

	
}
